using System;
using System.Collections.Generic;

namespace Shuttle.ESB.Core
{
    public interface IServiceBus : IDisposable
    {
		TransportMessage TransportMessageReceived { get; set; }

		string OutgoingCorrelationId { get; set; }
		List<TransportHeader> OutgoingHeaders { get; }
    	void ResetOutgoingHeaders();
		
		TransportMessage CreateTransportMessage(object message);

		TransportMessage Send(object message);
		TransportMessage Send(object message, string uri);
		TransportMessage Send(object message, IQueue queue);

		TransportMessage SendLocal(object message);
		TransportMessage SendReply(object message);

		IEnumerable<string> Publish(object message);

        IServiceBus Start();
        void Stop();
        bool Started { get; }
        
        IServiceBusConfiguration Configuration { get; }
		IServiceBusEvents Events { get; }
    }
}